package main

import (
	"fmt"
	"math/rand"
	"strconv"
	"theQuietClassroom/core"
)

func prtS(s core.Student_t) {
	fmt.Print(s.Name, " ")
}

func prtC(c core.Class_t) {
	for i := 0; i < len(c.Data); i++ {
		for j := 0; j < len(c.Data[i]); j++ {
			fmt.Print(c.Data[i][j].Name, " | ")

		}
		fmt.Println()
	}
	fmt.Println()
}

func main() {

	const (
		x = 5
		y = 3
	)

	dat := make([][]core.Student_t, x)

	for i := 0; i < x; i++ {
		for j := 0; j < y; j++ {
			stu := core.Student_t{
				Name:   strconv.Itoa(i) + "" + strconv.Itoa(j),
				Noise:  rand.Float64(),
				Height: 0.0,
				//ID:     strconv.Itoa(i) + strconv.Itoa(j),
			}
			dat[i] = append(dat[i], stu)
		}
	}

	class := core.Class_t{
		Data: dat,
		//Bests: make([]string, 0),
		//Len:   x * y,
	}

	prtC(class)

	for range 10 {
		go func() {
			a := rand.Intn(3)
			fmt.Println(a)
			fmt.Println(1)
		}()
	}
}
